<?php if (!defined ( 'BASEPATH' )) exit ('No direct script access allowed');

/**
* 语言model
*/
class Fnd_languages extends CI_Model
{
	
	function __construct()
	{
		parent::__construct();
	}

	public function get_default_lang()
	{
		$sql = "select fl.language_id, fl.language_code, fl.language_name, fl.folder as language_folder from fnd_languages fl where fl.front = 'Y' limit 1";
		$result = $this->db->query($sql);

		if($result->num_rows() < 1){
			$sql = "select fl.language_id, fl.language_code, fl.language_name, fl.folder as language_folder from fnd_languages fl LIMIT 1";
			$result = $this->db->query($sql);
		}

		return $result->row_array();
	}
}

/* End of file sys_config.php */
/* Location: ./application/models/sys/sys_config.php */